:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #1a1a1a;
    --bg-card: #252525;
    --bg-nav: #1f1f1f;
    --bg-overlay: rgba(0, 0, 0, 0.8);
  
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --text-muted: #808080;
  
    --accent-primary: #6366f1;
    --accent-secondary: #8b5cf6;
    --accent-hover: #4f46e5;
  
    --border-color: #333333;
    --border-radius: 12px;
    --border-radius-lg: 16px;
  
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.6);
  
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  }
  
  * {
    box-sizing: border-box;
  }
  
  body {
    margin: 0;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    position: static !important;
    transform: none !important;
    -webkit-transform: none !important;
  }
  
  /* Prevent page jumping when navigating */
  html {
    scroll-behavior: smooth;
    height: 100%;
    position: static !important;
    transform: none !important;
    -webkit-transform: none !important;
  }
  
  .nav {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: 70px !important;
    background: var(--bg-nav) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border-top: 1px solid var(--border-color) !important;
    display: flex !important;
    justify-content: space-around !important;
    align-items: center !important;
    z-index: 2147483647 !important;
    padding: 0 8px !important;
    transform: translateZ(0) !important;
    -webkit-transform: translateZ(0) !important;
    will-change: transform !important;
    width: 100vw !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }
  
  .nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 11px;
    font-weight: 500;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 8px 4px;
    border-radius: var(--border-radius);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
  }
  
  .nav a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
  }
  
  .nav a:hover::before,
  .nav a:focus::before {
    left: 0;
    opacity: 0.1;
  }
  
  .nav a:hover,
  .nav a:focus {
    color: var(--accent-primary);
    transform: translateY(-2px);
  }
  
  .nav img {
    width: 26px;
    height: 26px;
    filter: brightness(0.8);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .nav a:hover img,
  .nav a:focus img {
    filter: brightness(1);
    transform: scale(1.1);
  }
  
  .content {
    padding: 20px;
    padding-bottom: 90px; /* space for bottom nav */
    max-width: 1200px;
    margin: 0 auto;
  }

  /* Force navigation to always be on top */
  .nav {
    isolation: isolate !important;
    contain: layout style paint !important;
  }
  
  .page-title {
    margin: 0 0 24px 0;
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
  }
  
  .grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 30px;
    margin-top: 30px;
    padding: 0 10px;
  }
  
  /* Mobile responsive grid */
  @media (max-width: 768px) {
    .grid {
      grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
      gap: 20px;
      padding: 0 5px;
    }
  }
  
  @media (max-width: 480px) {
    .grid {
      grid-template-columns: 1fr;
      gap: 15px;
      padding: 0 5px;
    }
  }

  /* Desktop Enhancements */
  @media (min-width: 1024px) {
    .content {
      padding: 40px 30px;
      padding-bottom: 120px; /* more space for navigation */
      max-width: 1400px;
    }

    .grid {
      grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
      gap: 40px;
      padding: 0 20px;
    }

    .page-title {
      font-size: 3.5rem;
      margin-bottom: 40px;
      text-align: center;
    }

    .card {
      border-radius: 20px;
      transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .card:hover {
      transform: translateY(-12px) scale(1.03);
      box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
    }

    .card img {
      height: 280px;
    }

    .title {
      font-size: 1.3rem;
      font-weight: 700;
      line-height: 1.4;
    }

    .info-item {
      font-size: 0.95rem;
      padding: 8px 14px;
    }

    .nav {
      height: 80px !important;
      padding: 0 16px !important;
    }

    .nav a {
      font-size: 13px;
      padding: 10px 6px;
      gap: 8px;
    }

    .nav img {
      width: 28px;
      height: 28px;
    }

    /* Page headers for desktop */
    .page-header {
      margin-bottom: 80px;
      padding: 80px 60px;
      max-width: 1000px;
      margin-left: auto;
      margin-right: auto;
    }

    .page-title {
      font-size: 4.5rem;
      margin-bottom: 30px;
    }

    .page-subtitle {
      font-size: 1.6rem;
      margin-bottom: 30px;
      letter-spacing: 2px;
    }

    .page-description {
      max-width: 900px;
      font-size: 1.2rem;
      line-height: 1.9;
    }

    /* Buttons for desktop */
    .btn {
      padding: 16px 32px;
      font-size: 1.1rem;
      font-weight: 700;
      border-radius: 16px;
      transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .btn:hover {
      transform: translateY(-4px);
      box-shadow: var(--shadow-lg);
    }

    /* Enhanced card hover effects for desktop */
    .card {
      transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .card:hover {
      transform: translateY(-16px) scale(1.04);
    }

    /* History items for desktop */
    .history-item {
      border-radius: 20px;
      padding: 24px;
    }

    .history-item:hover {
      transform: translateY(-8px) scale(1.02);
    }

    .history-poster-container {
      border-radius: 16px;
    }

    /* Search container for desktop */
    .search-container {
      max-width: 600px;
      margin: 0 auto 40px;
    }

    .search-input {
      font-size: 1.1rem;
      padding: 16px 20px;
      border-radius: 16px;
    }

    /* Genre sections for desktop */
    .genres-section {
      padding: 60px 40px;
    }

    .genre-section {
      border-radius: 20px;
      padding: 40px;
    }

    .genre-title {
      font-size: 2.8rem;
    }

    /* Form elements for desktop */
    .search-input {
      font-size: 1.1rem;
      padding: 16px 20px;
      border-radius: 16px;
    }

    .search-btn {
      padding: 16px 32px;
      font-size: 1.1rem;
      border-radius: 16px;
    }

    .search-btn:hover {
      transform: translateY(-4px);
    }

    /* Modal enhancements for desktop */
    .modal-overlay {
      backdrop-filter: blur(8px);
      -webkit-backdrop-filter: blur(8px);
    }

    .modal-container {
      border-radius: 24px;
      max-width: 800px;
      margin: 40px auto;
    }

    .modal-header {
      padding: 32px 40px;
      font-size: 1.5rem;
    }

    .modal-body {
      padding: 32px 40px;
      max-height: 70vh;
    }

    .modal-footer {
      padding: 24px 40px;
    }

    /* Filter enhancements for desktop */
    .filter-section {
      padding: 24px;
      border-radius: 20px;
    }

    .checkbox-grid {
      grid-template-columns: repeat(2, 1fr);
      gap: 12px;
      max-height: 300px;
    }

    .checkbox-label {
      padding: 12px 16px;
      border-radius: 12px;
      font-size: 1rem;
    }

    /* Enhanced info items for desktop */
    .info-item {
      padding: 10px 16px;
      font-size: 1rem;
      border-radius: 12px;
    }
  }

  @media (min-width: 1440px) {
    .content {
      max-width: 1600px;
      padding: 50px 40px;
      padding-bottom: 140px;
    }

    .grid {
      grid-template-columns: repeat(auto-fill, minmax(420px, 1fr));
      gap: 50px;
      padding: 0 30px;
    }

    .page-title {
      font-size: 4rem;
      margin-bottom: 50px;
    }

    .card {
      border-radius: 24px;
    }

    .card img {
      height: 320px;
    }

    .title {
      font-size: 1.4rem;
    }

    .nav {
      height: 90px !important;
    }

    .nav a {
      font-size: 14px;
      padding: 12px 8px;
    }

    .nav img {
      width: 32px;
      height: 32px;
    }

    /* Enhanced desktop optimizations */
    .page-header {
      margin-bottom: 100px;
      padding: 100px 80px;
      max-width: 1200px;
    }

    .page-title {
      font-size: 5rem;
      margin-bottom: 40px;
    }

    .page-subtitle {
      font-size: 1.8rem;
      margin-bottom: 40px;
      letter-spacing: 2.5px;
    }

    .page-description {
      max-width: 1000px;
      font-size: 1.3rem;
      line-height: 2;
    }

    .btn {
      padding: 18px 36px;
      font-size: 1.2rem;
      border-radius: 20px;
    }

    .btn:hover {
      transform: translateY(-6px);
    }

    .card:hover {
      transform: translateY(-20px) scale(1.05);
    }

    .history-item {
      padding: 32px;
      border-radius: 24px;
    }

    .history-item:hover {
      transform: translateY(-10px) scale(1.03);
    }

    .search-container {
      max-width: 700px;
    }

    .search-input {
      font-size: 1.2rem;
      padding: 18px 24px;
      border-radius: 20px;
    }

    .genres-section {
      padding: 80px 60px;
    }

    .genre-section {
      padding: 50px;
      border-radius: 24px;
    }

    .genre-title {
      font-size: 3.2rem;
    }

    /* Enhanced form elements */
    .search-input {
      font-size: 1.2rem;
      padding: 18px 24px;
      border-radius: 20px;
    }

    .search-btn {
      padding: 18px 36px;
      font-size: 1.2rem;
      border-radius: 20px;
    }

    .modal-container {
      max-width: 900px;
      border-radius: 28px;
    }

    .modal-header {
      padding: 40px 50px;
      font-size: 1.7rem;
    }

    .modal-body {
      padding: 40px 50px;
      max-height: 75vh;
    }

    .modal-footer {
      padding: 32px 50px;
    }

    .checkbox-grid {
      grid-template-columns: repeat(3, 1fr);
      gap: 14px;
      max-height: 350px;
    }

    .checkbox-label {
      padding: 14px 18px;
      border-radius: 14px;
      font-size: 1.05rem;
    }

    .info-item {
      padding: 12px 18px;
      font-size: 1.05rem;
      border-radius: 14px;
    }
  }

  @media (min-width: 1920px) {
    .content {
      max-width: 1800px;
      padding: 60px 50px;
      padding-bottom: 160px;
    }

    .grid {
      grid-template-columns: repeat(6, 1fr);
      gap: 60px;
      padding: 0 40px;
    }

    .page-title {
      font-size: 4.5rem;
      margin-bottom: 60px;
    }

    .card {
      border-radius: 28px;
    }

    .card img {
      height: 360px;
    }

    .title {
      font-size: 1.5rem;
    }

    .nav {
      height: 100px !important;
    }

    .nav a {
      font-size: 15px;
      padding: 14px 10px;
    }

    .nav img {
      width: 36px;
      height: 36px;
    }

    /* Ultra-wide desktop optimizations */
    .page-header {
      margin-bottom: 120px;
      padding: 120px 100px;
      max-width: 1400px;
    }

    .page-title {
      font-size: 6rem;
      margin-bottom: 50px;
    }

    .page-subtitle {
      font-size: 2rem;
      margin-bottom: 50px;
      letter-spacing: 3px;
    }

    .page-description {
      max-width: 1200px;
      font-size: 1.4rem;
      line-height: 2.1;
    }

    .btn {
      padding: 20px 40px;
      font-size: 1.3rem;
      border-radius: 24px;
    }

    .btn:hover {
      transform: translateY(-8px);
    }

    .card:hover {
      transform: translateY(-24px) scale(1.06);
    }

    .history-item {
      padding: 40px;
      border-radius: 28px;
    }

    .history-item:hover {
      transform: translateY(-12px) scale(1.04);
    }

    .search-container {
      max-width: 800px;
    }

    .search-input {
      font-size: 1.3rem;
      padding: 20px 28px;
      border-radius: 24px;
    }

    .genres-section {
      padding: 100px 80px;
    }

    .genre-section {
      padding: 60px;
      border-radius: 28px;
    }

    .genre-title {
      font-size: 3.6rem;
    }

    /* Ultra-wide form elements */
    .search-input {
      font-size: 1.3rem;
      padding: 20px 28px;
      border-radius: 24px;
    }

    .search-btn {
      padding: 20px 40px;
      font-size: 1.3rem;
      border-radius: 24px;
    }

    .modal-container {
      max-width: 1000px;
      border-radius: 32px;
    }

    .modal-header {
      padding: 48px 60px;
      font-size: 1.9rem;
    }

    .modal-body {
      padding: 48px 60px;
      max-height: 80vh;
    }

    .modal-footer {
      padding: 40px 60px;
    }

    .checkbox-grid {
      grid-template-columns: repeat(4, 1fr);
      gap: 16px;
      max-height: 400px;
    }

    .checkbox-label {
      padding: 16px 20px;
      border-radius: 16px;
      font-size: 1.1rem;
    }

    .info-item {
      padding: 14px 20px;
      font-size: 1.1rem;
      border-radius: 16px;
    }
  }
  
  .card {
    background: linear-gradient(145deg, rgba(0, 0, 0, 0.4), rgba(255, 255, 255, 0.05));
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(15px);
    position: relative;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    text-decoration: none;
    color: var(--text-primary);
  }
  
  .card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-primary);
    opacity: 0;
    z-index: 1;
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .card:hover::before {
    opacity: 0.1;
  }
  
  .card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    border-color: rgba(255, 255, 255, 0.3);
    background: linear-gradient(145deg, rgba(0, 0, 0, 0.5), rgba(255, 255, 255, 0.08));
  }
  
  /* Mobile card adjustments */
  @media (max-width: 768px) {
    .card {
      border-radius: 16px;
    }
  
    .card img {
      height: 200px;
    }
  
    .card:hover {
      transform: translateY(-8px) scale(1.02);
    }
  
    .title {
      font-size: 1rem;
      line-height: 1.3;
    }
  
    .info-item {
      font-size: 0.85rem;
      padding: 4px 10px;
    }
  }
  
  @media (max-width: 480px) {
    .card {
      border-radius: 12px;
    }
  
    .card img {
      height: 180px;
    }
  
    .card:hover {
      transform: translateY(-4px) scale(1.01);
    }
  
    .title {
      font-size: 0.95rem;
      line-height: 1.2;
    }
  
    .info-item {
      font-size: 0.8rem;
      padding: 3px 8px;
      gap: 4px;
    }
  
    .count-number {
      font-size: 0.9rem;
    }
  
    .count-label {
      font-size: 0.75rem;
    }
  }
  
  /* Enhanced Genres Page Styles */
  .genres-page {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px;
  }
  
  .page-header {
    text-align: center;
    margin-bottom: 60px;
    padding: 50px 30px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
  }
  
  .page-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin: 0 0 20px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 40px rgba(102, 126, 234, 0.3);
  }
  
  .page-subtitle {
    font-size: 1.4rem;
    color: #b0b0b0;
    font-weight: 500;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
  }
  
  .page-description {
    max-width: 800px;
    margin: 0 auto;
    color: #d0d0d0;
    line-height: 1.8;
    font-size: 1.1rem;
  }
  
  .page-description p {
    margin: 0 0 15px 0;
  }
  
  .page-description p:last-child {
    margin-bottom: 0;
  }
  
  .genres-section {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px;
  }
  
  
  
  .genre-section:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.15);
  }
  
  .section-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
  }
  
  .genre-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin: 0 0 15px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(102, 126, 234, 0.3);
  }
  
  .genre-subtitle {
    font-size: 1.2rem;
    color: #b0b0b0;
    font-weight: 500;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
  }
  
  .genre-count {
    display: inline-block;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    padding: 8px 20px;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: 0 4px 15px rgba(240, 147, 251, 0.3);
  }
  
  .genre-carousel {
    position: relative;
    overflow: hidden;
    padding: 0 20px;
  }

  .carousel-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
    padding: 20px 0;
  }

  /* Carousel Navigation */
  .carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
  }

  .carousel-nav:hover {
    background: rgba(102, 126, 234, 0.1);
    border-color: rgba(102, 126, 234, 0.3);
    transform: translateY(-50%) scale(1.1);
  }

  .carousel-nav.prev {
    left: 10px;
  }

  .carousel-nav.next {
    right: 10px;
  }

  .carousel-nav svg {
    width: 20px;
    height: 20px;
    color: #4a5568;
  }
  
  .carousel-container .card {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(248, 250, 252, 0.9));
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    text-decoration: none;
    color: inherit;
    height: 380px;
    position: relative;
  }

  .carousel-container .card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    opacity: 0;
    z-index: 1;
    transition: opacity 0.3s ease;
  }
  
  .carousel-container .card:hover::before {
    opacity: 0.1;
  }
  
  .carousel-container .card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
    border-color: rgba(102, 126, 234, 0.3);
  }

  .carousel-container .card img {
    width: 100%;
    height: 260px;
    object-fit: cover;
    transition: all 0.3s ease;
  }

  .carousel-container .card:hover img {
    transform: scale(1.03);
  }

  .carousel-container .card-content {
    padding: 16px;
    position: relative;
    z-index: 2;
    background: #ffffff;
    backdrop-filter: blur(10px);
  }

  .carousel-container .card .title {
    font-size: 1rem;
    font-weight: 600;
    color: #1a202c !important;
    margin: 0 0 8px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: none;
  }
  
  .carousel-container .card-info {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
  }
  
  .carousel-container .card .info-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 6px 10px;
    background: rgba(248, 250, 252, 0.8);
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
  }
  
  .carousel-container .card .info-item:hover {
    background: rgba(102, 126, 234, 0.1);
    transform: translateY(-2px);
    border-color: rgba(102, 126, 234, 0.2);
  }
  
  .carousel-container .card .count-number {
    font-size: 1.1rem;
    font-weight: 700;
    color: #667eea;
  }
  
  .carousel-container .card .count-label {
    font-size: 0.8rem;
    color: #b0b0b0;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  
  /* Mobile responsive genres page */
  @media (max-width: 768px) {
    .genres-page {
      padding: 20px 15px;
    }
    
    .page-header {
      margin-bottom: 40px;
      padding: 30px 20px;
    }
    
    .page-title {
      font-size: 2.5rem;
    }
    
    .page-subtitle {
      font-size: 1.2rem;
    }
    
    .page-description {
      font-size: 1rem;
    }
    
    .genres-section {
      margin: 20px 0;
      padding: 15px 10px;
    }
    
    .genre-section {
      margin-bottom: 40px;
      padding: 25px 20px;
      border-radius: 20px;
    }
    
    .genre-title {
      font-size: 2rem;
    }
    
    .genre-subtitle {
      font-size: 1rem;
    }
    
    .carousel-container {
      grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
      gap: 20px;
      padding: 15px 0;
    }
    
    .carousel-container .card {
      height: 380px;
    }
    
    .carousel-container .card img {
      height: 240px;
    }
    
    .carousel-container .card-content {
      padding: 15px;
    }
    
    .carousel-container .card .title {
      font-size: 1rem;
      margin-bottom: 12px;
    }
    
    .carousel-container .card-info {
      gap: 12px;
    }
    
    .carousel-container .card .info-item {
      padding: 6px 10px;
    }
  }
  
  @media (max-width: 480px) {
    .genres-page {
      padding: 15px 10px;
    }
    
    .page-header {
      margin-bottom: 30px;
      padding: 25px 15px;
    }
    
    .page-title {
      font-size: 2rem;
    }
    
    .page-subtitle {
      font-size: 1rem;
    }
    
    .page-description {
      font-size: 0.9rem;
    }
    
    .genres-section {
      padding: 10px 5px;
    }
    
    .genre-section {
      padding: 20px 15px;
      margin-bottom: 30px;
    }
    
    .genre-title {
      font-size: 1.8rem;
    }
    
    .carousel-container {
      grid-template-columns: 1fr;
      gap: 15px;
    }
    
    .carousel-container .card {
      height: 360px;
    }
    
    .carousel-container .card img {
      height: 220px;
    }
    
    .carousel-container .card-content {
      padding: 12px;
    }
    
    .carousel-container .card .title {
      font-size: 0.95rem;
    }
  }
  
    .genre-section {
      margin-bottom: 30px;
      padding: 20px 15px;
    }
  
    .genre-title {
      font-size: 1.4rem;
    }
  
    .genre-subtitle {
      font-size: 0.9rem;
    }
  
    .genre-count {
      font-size: 0.8rem;
      padding: 3px 10px;
    }
  
    .page-header {
      padding: 20px 15px;
    }
  
    .page-title {
      font-size: 2rem;
    }
  
    .page-subtitle {
      font-size: 1rem;
    }
  
    .page-description {
      font-size: 0.9rem;
    }
  
  
  /* Mobile page elements */
  @media (max-width: 768px) {
    .catalog-header {
      margin-bottom: 24px;
    }
  
    .page-title {
      font-size: 2rem;
    }
  
    .catalog-subtitle {
      font-size: 1rem;
    }
  
    .empty-state {
      padding: 40px 15px;
    }
  
    .empty-icon {
      font-size: 3rem;
    }
  
    .page-header {
      padding: 30px 15px;
    }
  
    .page-title {
      font-size: 2.5rem;
    }
  
    .page-subtitle {
      font-size: 1.2rem;
    }
  }
  
  @media (max-width: 480px) {
    .catalog-header {
      margin-bottom: 20px;
    }
  
    .page-title {
      font-size: 1.8rem;
    }
  
    .catalog-subtitle {
      font-size: 0.9rem;
    }
  
    .empty-state {
      padding: 30px 10px;
    }
  
    .empty-icon {
      font-size: 2.5rem;
    }
  
    .page-header {
      padding: 20px 10px;
    }
  
    .page-title {
      font-size: 2rem;
    }
  
    .page-subtitle {
      font-size: 1rem;
    }
  
    .page-description {
      font-size: 0.9rem;
    }
  }
  
  .card img {
    width: 100%;
    height: 240px;
    object-fit: cover;
    display: block;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .card:hover img {
    transform: scale(1.03);
  }
  
  .card .card-content {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 16px 12px;
    background: linear-gradient(to top, rgba(0,0,0,0.95), rgba(0,0,0,0.7), transparent);
    z-index: 2;
    backdrop-filter: blur(4px);
  }
  
  .card .title {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 8px;
  }
  
  .card-info {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
  }
  
  .info-item {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    padding: 2px 6px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 4px;
    backdrop-filter: blur(2px);
  }
  
  .count-number {
    font-size: 0.8rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
  }
  
  .count-label {
    font-size: 0.7rem;
    font-weight: 500;
    opacity: 0.7;
    text-transform: uppercase;
  }
  
  .detail-header .cover {
    width: 100%;
    border-radius: var(--border-radius-lg);
    margin-bottom: 2rem;
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .detail-header .cover:hover {
    transform: scale(1.02);
  }
  
  .detail-header .description {
    margin: 1.5rem 0;
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--text-secondary);
  }
  
  .detail-header .meta {
    margin: 0.75rem 0;
    color: var(--text-muted);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
  }
  
  .detail-header .meta::before {
    content: '•';
    color: var(--accent-primary);
    font-weight: bold;
  }
  
  .season {
    background: var(--bg-secondary);
    border-radius: var(--border-radius-lg);
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid var(--border-color);
  }
  
  .season h2 {
    margin: 0 0 20px 0;
    font-size: 1.5rem;
    font-weight: 600;
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }
  
  .episode-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 12px;
  }
  
  .episode-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: var(--bg-card);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .episode-item:hover {
    transform: translateX(4px);
    border-color: var(--accent-primary);
    box-shadow: var(--shadow-md);
  }
  
  .btn {
    background: var(--gradient-primary);
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
  }
  
  .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
  }
  
  .btn:hover::before {
    left: 100%;
  }
  
  .btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
  }
  
  .btn:active {
    transform: translateY(0);
  }
  
  /* Loading animation */
  @keyframes shimmer {
    0% {
      background-position: -200px 0;
    }
    100% {
      background-position: calc(200px + 100%) 0;
    }
  }
  
  .loading {
    background: linear-gradient(90deg, var(--bg-card) 0%, var(--bg-secondary) 50%, var(--bg-card) 100%);
    background-size: 200px 100%;
    animation: shimmer 1.5s infinite;
  }
  
  @keyframes fadeIn {
    from {
      opacity: 0;
      transform: translateY(20px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .fade-in {
    animation: fadeIn 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  /* Responsive design */
  @media (max-width: 768px) {
    .content {
      padding: 16px;
      padding-bottom: 90px;
    }
  
    .page-title {
      font-size: 2rem;
    }
  
    .grid {
      grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
      gap: 16px;
    }
  
    .card img {
      height: 200px;
    }
  
    .season {
      padding: 16px;
    }
  
    .episode-item {
      padding: 12px 16px;
    }
  }
  
  /* Dark theme enhancements */
  ::-webkit-scrollbar {
    width: 8px;
  }
  
  ::-webkit-scrollbar-track {
    background: var(--bg-primary);
  }
  
  ::-webkit-scrollbar-thumb {
    background: var(--bg-secondary);
    border-radius: 4px;
  }
  
  ::-webkit-scrollbar-thumb:hover {
    background: var(--accent-primary);
  }
  
  /* Selection styling */
  ::selection {
    background: var(--accent-primary);
    color: white;
  }
  
  ::-moz-selection {
    background: var(--accent-primary);
    color: white;
  }
  
  /* Catalog specific styles */
  .catalog-header {
    text-align: center;
    margin-bottom: 32px;
  }
  
  .catalog-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin: 8px 0 0 0;
    font-weight: 400;
  }
  
  .empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
  }
  
  .empty-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.6;
  }
  
  .empty-state h2 {
    margin: 0 0 12px 0;
    color: var(--text-secondary);
    font-size: 1.5rem;
    font-weight: 600;
  }
  
  .empty-state p {
    margin: 0;
    font-size: 1rem;
  }
  
  /* Enhanced card effects */
  .card {
    position: relative;
  }
  
  .card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.1) 50%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
  }
  
  .card:hover::after {
    opacity: 1;
  }
  
  /* Detail page specific styles */
  .detail-header {
    margin-bottom: 40px;
  }
  
  .cover-container {
    text-align: center;
    margin-bottom: 32px;
  }
  
  .title-section {
    text-align: center;
    margin-bottom: 24px;
  }
  
  .meta-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin: 16px 0;
  }
  
  .meta-item {
    background: var(--bg-secondary);
    padding: 8px 16px;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
  }
  
  .description-section {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
  }
  
  .seasons-container {
    display: flex;
    flex-direction: column;
    gap: 32px;
  }
  
  .season-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
  }
  
  .season-title {
    margin: 0;
    font-size: 1.8rem;
    font-weight: 700;
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }
  
  .episode-count {
    background: var(--accent-primary);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
  }
  
  .episode-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
  }
  
  .episode-number {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent-primary);
    display: inline-block;
    min-width: 30px;
    text-align: center;
    background: rgba(102, 126, 234, 0.1);
    border-radius: 6px;
    padding: 2px 6px;
    margin-right: 8px;
  }
  
  .episode-count-badge {
    background: linear-gradient(135deg, #ff6b6b 0%, #4ecdc4 100%);
    color: white !important;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
  }
  
  /* Sort Section in Modal */
  .sort-section {
    margin-bottom: 32px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
  }
  
  .sort-section .sort-select {
    width: 100%;
    padding: 12px 16px;
    background: white;
    border: 1px solid #dadce0;
    border-radius: 8px;
    font-size: 0.95rem;
    color: #202124;
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
  }
  
  .sort-section .sort-select:focus {
    border-color: #4285f4;
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.2);
  }
  
  .sort-section .sort-select:hover {
    border-color: #dadce0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  }
  
  .episode-title {
    color: var(--text-secondary);
    font-size: 0.95rem;
  }
  
  .watch-btn {
    min-width: 100px;
  }
  
  .btn-text {
    display: flex;
    align-items: center;
    gap: 8px;
  }
  
  /* Mobile optimizations */
  @media (max-width: 768px) {
    .meta-grid {
      flex-direction: column;
      align-items: center;
    }
  
    .season-header {
      flex-direction: column;
      gap: 12px;
      align-items: stretch;
    }
  
    .season-title {
      font-size: 1.5rem;
    }
  }
  
  /* Notification system */
  .notification {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    padding: 16px 20px;
    border-radius: var(--border-radius);
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: var(--shadow-xl);
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    max-width: 300px;
    backdrop-filter: blur(10px);
  }
  
  .notification--show {
    transform: translateX(0);
  }
  
  .notification--success {
    background: linear-gradient(135deg, #10b981, #059669);
  }
  
  .notification--error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
  }
  
  .notification--info {
    background: var(--gradient-primary);
  }
  
  /* Enhanced button states */
  .btn--loading {
    pointer-events: none;
    opacity: 0.7;
  }
  
  .btn--success {
    background: linear-gradient(135deg, #10b981, #059669);
    animation: pulse 0.6s ease-in-out;
  }
  
  .btn--error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    animation: shake 0.6s ease-in-out;
  }
  
  .loading-text,
  .success-text,
  .error-text {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
  }
  
  /* Touch feedback */
  .touch-active {
    transform: scale(0.98);
  }
  
  /* Enhanced animations */
  @keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
  }
  
  @keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
  }
  
  .fade-in-visible {
    opacity: 1;
    transform: translateY(0);
  }
  
  /* Performance optimizations */
  .card,
  .season,
  .btn {
    will-change: transform;
    transform: translateZ(0);
  }
  
  /* Focus improvements for accessibility */
  .card:focus,
  .btn:focus {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
  }
  
  /* Error page styles */
  .error-container {
    text-align: center;
    padding: 60px 20px;
  }
  
  .error-icon {
    margin-bottom: 20px;
  }
  
  .error-message {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin: 20px 0 40px 0;
  }
  
  /* Search Section */
  .search-section {
    padding: 24px 30px;
    margin-bottom: 40px;
  }
  
  .search-container {
    display: flex;
    align-items: center;
    gap: 16px;
    max-width: 800px;
    margin: 0 auto;
  }
  
  .search-form {
    flex: 1;
    position: relative;
  }
  
  .search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
  }
  
  .search-input {
    width: 100%;
    padding: 18px 60px 18px 24px;
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 30px;
    font-size: 16px;
    color: #202124;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    outline: none;
    backdrop-filter: blur(20px);
  }
  
  .search-input:focus {
    border-color: #4285f4;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2), 0 0 0 4px rgba(66, 133, 244, 0.15);
    background: rgba(255, 255, 255, 1);
    transform: scale(1.02);
    color: #202124;
  }
  
  .search-input:hover {
    border-color: rgba(66, 133, 244, 0.3);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
    background: rgba(255, 255, 255, 1);
    color: #202124;
  }
  
  .search-input::placeholder {
    color: #9aa0a6;
    font-weight: 400;
  }
  
  .search-input:focus::placeholder {
    color: #5f6368;
  }
  
  .search-input:hover::placeholder {
    color: #5f6368;
  }
  
  .search-button {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, #4285f4, #34a853);
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 16px rgba(66, 133, 244, 0.4);
  }
  
  .search-button:hover {
    background: linear-gradient(135deg, #3367d6, #2d8f47);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 8px 24px rgba(66, 133, 244, 0.5);
  }
  
  .search-button:active {
    transform: translateY(-50%) scale(0.95);
  }
  
  .search-button svg {
    width: 18px;
    height: 18px;
    color: white;
  }
  
  /* Mobile responsive search bar */
  @media (max-width: 768px) {
    .search-section {
      padding: 20px 15px;
      margin-bottom: 30px;
    }
  
    .search-container {
      flex-direction: row;
      gap: 12px;
      max-width: none;
      width: 100%;
    }
  
    .search-form {
      flex: 1;
    }
  
    .search-input {
      padding: 14px 45px 14px 18px;
      font-size: 16px; /* Prevents zoom on iOS */
      border-radius: 20px;
    }
  
    .search-button {
      width: 44px;
      height: 44px;
      right: 6px;
    }
  
    .search-button svg {
      width: 16px;
      height: 16px;
    }
  
    .filter-button {
      min-width: 110px;
      padding: 12px 16px;
    font-size: 0.85rem;
      height: 44px;
      border-radius: 8px;
    }
  }
  
  @media (max-width: 480px) {
    .search-section {
      padding: 15px 10px;
    }
  
    .search-container {
      gap: 10px;
    }
  
    .search-input {
      font-size: 16px;
      padding: 12px 40px 12px 16px;
      border-radius: 18px;
    }
  
    .search-button {
      width: 40px;
      height: 40px;
      right: 5px;
    }
  
    .search-button svg {
      width: 15px;
      height: 15px;
    }
  
    .filter-button {
      min-width: 90px;
      padding: 10px 12px;
      font-size: 0.8rem;
      height: 40px;
      border-radius: 6px;
  }
  
  /* Filter Results Info */
  .filter-results-info {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 20px 25px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
  }
  
  .filter-summary {
    display: flex;
    flex-direction: column;
    gap: 4px;
  }
  
  .filter-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
  }
  
  .filter-details {
    font-size: 0.9rem;
    color: var(--text-secondary);
    opacity: 0.8;
    font-style: italic;
  }
  
  .results-count {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
  }
  
  .results-count .count-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a73e8;
  }
  
  .count-text {
    color: var(--text-secondary);
    font-weight: 500;
  }
  
  .original-count {
    color: var(--text-muted);
    font-size: 0.9rem;
    opacity: 0.7;
  }
  
  /* Mobile responsive filter results */
  @media (max-width: 768px) {
    .filter-results-info {
      flex-direction: column;
      align-items: flex-start;
      gap: 10px;
    }
  
    .filter-summary {
      width: 100%;
    }
  
    .results-count {
      font-size: 0.95rem;
    }
  
    .results-count .count-number {
      font-size: 1.3rem;
    }
  }
  
  
  
  /* Detail Page Styles */
  .back-button-container {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1000;
  }
  
  .back-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 25px;
    color: white;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  }
  
  .back-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.4);
  }
  
  /* Main anime detail section */
  .anime-detail {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 20px;
    align-items: start;
  }
  
  .anime-poster {
    position: sticky;
    top: 80px;
  }
  
  .poster-img {
    width: 100%;
    max-width: 300px;
    height: 420px;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 3px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
  }
  
  .poster-img:hover {
    transform: scale(1.02);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.4);
  }
  
  .anime-info {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .anime-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: white;
    margin: 0 0 30px 0;
    line-height: 1.2;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  }
  
  .anime-meta {
    margin-bottom: 30px;
  }
  
  .meta-row {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .meta-row:last-child {
    border-bottom: none;
  }
  
  .meta-label {
    font-weight: 600;
    color: #b3b3b3;
    min-width: 120px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.95rem;
  }
  
  .meta-value {
    color: white;
    font-size: 0.95rem;
    font-weight: 500;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }
  
  /* Badge styles */
  .year-badge, .genre-badge, .theme-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    text-align: center;
    transition: all 0.3s ease;
    cursor: default;
  }
  
  .year-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
  }
  
  .year-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  }
  
  .genre-badge {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(240, 147, 251, 0.3);
  }
  
  .genre-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(240, 147, 251, 0.4);
  }
  
  .theme-badge {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(79, 172, 254, 0.3);
  }
  
  .theme-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 172, 254, 0.4);
  }
  
  .episode-count {
    color: #667eea;
    font-weight: 700;
  }
  
  .anime-description {
    margin-top: 30px;
  }
  
  .anime-description h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    margin: 0 0 20px 0;
  }
  
  .description-container {
    position: relative;
  }
  
  .description-text {
    color: #e0e0e0;
    font-size: 1rem;
    line-height: 1.7;
    margin: 0 0 20px 0;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: all 0.3s ease;
  }
  
  .description-text.expanded {
    display: block;
    -webkit-line-clamp: unset;
  }
  
  .toggle-description-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 25px;
    color: white;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
  }
  
  .toggle-description-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
  }
  
  .toggle-description-btn svg {
    transition: transform 0.3s ease;
  }
  
  .toggle-description-btn.rotated svg {
    transform: rotate(180deg);
  }
  
  /* Episodes Section */
  .episodes-section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
  }
  
  .section-title {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    margin: 0 0 30px 0;
    text-align: center;
  }
  
  .season-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
  }
  
  .season-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  
  .season-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: white;
    margin: 0;
  }
  
  .episode-count-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    color: white;
    font-weight: 600;
  }
  
  .episodes-grid {
    padding: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 8px;
  }
  
  .episode-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
  }
  
  .episode-card:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
  }
  
  .episode-card.not-sent {
    border-color: rgba(244, 67, 54, 0.3);
    background: rgba(244, 67, 54, 0.05);
  }
  
  .episode-card.not-sent .episode-number {
    color: #ff8a80;
  }
  
  .episode-card.not-sent .watch-episode-btn {
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
    opacity: 0.7;
  }
  
  .episode-card.not-sent .watch-episode-btn:hover {
    opacity: 1;
    box-shadow: 0 4px 15px rgba(244, 67, 54, 0.3);
  }
  
  .episode-number {
    font-size: 0.8rem;
    font-weight: 700;
    color: #667eea;
    margin-bottom: 6px;
  }
  
  .watch-episode-btn {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 15px;
    padding: 6px 8px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-size: 0.7rem;
  }
  
  .watch-episode-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
  }
  
  .watch-episode-btn.sent-to-bot {
    background: linear-gradient(135deg, #4caf50 0%, #45a049 100%);
  }
  
  .watch-episode-btn.sent-to-bot:hover {
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
  }
  
  .watch-episode-btn.error-state {
    background: linear-gradient(135deg, #ff5722 0%, #d84315 100%);
    animation: errorPulse 2s infinite;
  }
  
  .watch-episode-btn.error-state:hover {
    box-shadow: 0 4px 15px rgba(255, 87, 34, 0.4);
  }
  
  @keyframes errorPulse {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
  }
  
  /* No episodes state */
  .no-episodes {
    text-align: center;
    padding: 60px 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin: 40px auto;
    max-width: 500px;
  }
  
  .no-episodes-icon {
    margin-bottom: 20px;
  }
  
  .no-episodes-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    margin: 0 0 10px 0;
  }
  
  .no-episodes-text {
    color: #b3b3b3;
    font-size: 1rem;
    margin: 0;
  }
  
  /* Mobile responsive */
  @media (max-width: 1024px) {
    .anime-detail {
      grid-template-columns: 1fr;
      gap: 30px;
      margin-top: 40px;
    }
  
    .anime-poster {
      position: static;
      text-align: center;
    }
  
    .poster-img {
      max-width: 250px;
    }
  }
  
  @media (max-width: 768px) {
    .back-button-container {
      top: 15px;
      left: 15px;
    }
  
    .back-btn {
      padding: 10px 16px;
      font-size: 0.9rem;
    }
  
    .anime-detail {
      margin: 40px 15px;
      padding: 0;
    }
  
    .anime-info {
      padding: 25px;
    }
  
    .anime-title {
      font-size: 2rem;
    }
  
    .meta-label {
      min-width: 100px;
      font-size: 0.9rem;
    }
  
    .meta-value {
      font-size: 0.9rem;
    }
  
    .episodes-section {
      padding: 0 15px;
    }
  
    .section-title {
      font-size: 1.8rem;
    }
  
    .episodes-grid {
      grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
      gap: 6px;
      padding: 15px;
    }
  
    .season-header {
      padding: 15px 20px;
      flex-direction: column;
      gap: 8px;
      align-items: flex-start;
    }
  
    .episode-card {
      padding: 8px;
    }
  
    .episode-number {
      font-size: 0.7rem;
      margin-bottom: 4px;
    }
  
    .watch-episode-btn {
      padding: 4px 6px;
      font-size: 0.65rem;
      border-radius: 12px;
    }
  
    .no-episodes {
      margin: 20px 15px;
      padding: 40px 20px;
    }
  
  
  }
  
  /* Genres Section */
  .genres-section {
    margin: 40px 0;
    padding: 40px 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
  }
  
  .genres-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #667eea);
  }
  
  .section-divider {
    text-align: center;
    margin-bottom: 40px;
    padding: 0 20px;
  }
  
  .section-divider .section-title {
    font-size: 2.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  }
  
  .section-divider .section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin: 0;
  }
  
  /* Individual Genre Sections */
  .genre-section {
    margin-bottom: 40px;
    padding: 25px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
  }
  
  .genre-section .section-header {
    margin-bottom: 25px;
    padding: 0;
    text-align: center;
  }
  
  .genre-title {
    font-size: 1.6rem;
    font-weight: 800;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0 0 8px 0;
    letter-spacing: -0.02em;
  }
  
  .genre-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin: 0 0 8px 0;
  }
  
  .genre-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin: 0 0 8px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  
  .genre-count {
    font-size: 0.9rem;
    color: #1a73e8;
    font-weight: 600;
    margin: 0;
    padding: 4px 12px;
    background: rgba(26, 115, 232, 0.1);
    border-radius: 20px;
    display: inline-block;
  }
  
  .genre-carousel {
    position: relative;
    overflow: hidden;
  }
  
  .carousel-container {
    display: flex;
    gap: 16px;
    padding: 0 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }
  
  .carousel-container::-webkit-scrollbar {
    display: none;
  }
  
  .carousel-container .card {
    flex: 0 0 200px;
    min-width: 200px;
    max-width: 200px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .carousel-container .card:hover {
    transform: scale(1.05) translateY(-8px);
  }
  
  .carousel-container .card img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: var(--border-radius);
  }
  
  .carousel-container .card .card-content {
    padding: 12px;
  }
  
  .carousel-container .card .title {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  
  .carousel-container .card .card-info {
    flex-direction: column;
    gap: 4px;
  }
  
  .carousel-container .card .info-item {
    font-size: 0.75rem;
  }
  
  /* Mobile responsive for genre sections */
  @media (max-width: 768px) {
    .carousel-container .card {
      flex: 0 0 160px;
      min-width: 160px;
      max-width: 160px;
    }
  
    .carousel-container .card img {
      height: 240px;
    }
  
    .section-title {
      font-size: 1.3rem;
    }
  
    .genres-section {
      margin-top: 40px;
      padding: 30px 0;
    }
  
    .section-divider .section-title {
      font-size: 1.6rem;
    }
  
    .section-divider .section-subtitle {
      font-size: 1rem;
    }
  
    .genre-title {
      font-size: 1.2rem;
    }
  
    .genre-title::before {
      width: 3px;
      height: 20px;
    }
  }
  
  @media (max-width: 480px) {
    .carousel-container .card {
      flex: 0 0 140px;
      min-width: 140px;
      max-width: 140px;
    }
  
    .carousel-container .card img {
      height: 200px;
    }
  
    .section-divider .section-title {
      font-size: 1.4rem;
    }
  
    .genre-title {
      font-size: 1.1rem;
    }
  }
  
  /* Genres Page Specific Styles */
  .genres-page {
    padding: 30px 0 50px;
    background:
      radial-gradient(circle at 25% 25%, rgba(255, 107, 107, 0.05) 0%, transparent 50%),
      radial-gradient(circle at 75% 75%, rgba(78, 205, 196, 0.05) 0%, transparent 50%),
      radial-gradient(circle at 50% 50%, rgba(102, 126, 234, 0.03) 0%, transparent 50%),
      linear-gradient(180deg, rgba(26, 26, 26, 0.02) 0%, rgba(26, 26, 26, 0.05) 100%);
    min-height: 100vh;
    position: relative;
    overflow: hidden;
  }
  
  .genres-page::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
      url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ff6b6b' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
    pointer-events: none;
  }
  
  .page-header {
    text-align: center;
    margin-bottom: 60px;
    padding: 0 20px;
    position: relative;
  }
  
  .page-header .page-title {
    font-size: 3.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, #ff6b6b 0%, #4ecdc4 25%, #45b7d1 50%, #96ceb4 75%, #ffeaa7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0 0 16px 0;
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    letter-spacing: -0.02em;
    line-height: 1.1;
    animation: titleGlow 3s ease-in-out infinite alternate;
  }
  
  @keyframes titleGlow {
    from {
      filter: brightness(1) drop-shadow(0 4px 8px rgba(0, 0, 0, 0.15));
    }
    to {
      filter: brightness(1.1) drop-shadow(0 6px 12px rgba(0, 0, 0, 0.2));
    }
  }
  
  .page-header .page-subtitle {
    font-size: 1.4rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin: 0 0 20px 0;
    opacity: 0.9;
  }
  
  .page-description {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    padding: 25px;
    margin-top: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  }
  
  .page-description p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--text-primary);
    margin: 0 0 15px 0;
    text-align: center;
  }
  
  .page-description p:last-child {
    margin-bottom: 0;
    font-weight: 600;
    color: #667eea;
  }
  
  /* Enhanced Genre Sections */
  .genre-section {
    margin-bottom: 50px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(15px);
    border-radius: 25px;
    padding: 35px;
    margin: 0 20px 50px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
  }
  
  .genre-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #ffeaa7);
    background-size: 200% 100%;
    animation: gradientShift 3s ease-in-out infinite;
  }
  
  @keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
  }
  
  .genre-section:hover {
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    background: rgba(50, 49, 66, 0.95);
  }
  
  .section-header {
    text-align: center;
    margin-bottom: 25px;
  }
  
  .genre-title {
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0 0 8px 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  }
  
  .genre-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin: 0 0 12px 0;
  }
  
  .genre-count {
    font-size: 0.95rem;
    color: #ff6b6b;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(255, 107, 107, 0.1);
    padding: 4px 12px;
    border-radius: 15px;
    display: inline-block;
  }
  
  /* Enhanced Carousel */
  .genre-carousel {
    position: relative;
  }
  
  .carousel-container {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding-bottom: 10px;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }
  
  .carousel-container::-webkit-scrollbar {
    display: none;
  }
  
  /* Scroll indicators */
  .carousel-container::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 30px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.8) 0%, transparent 100%);
    pointer-events: none;
    z-index: 1;
  }
  
  .carousel-container::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 30px;
    background: linear-gradient(-90deg, rgba(255, 255, 255, 0.8) 0%, transparent 100%);
    pointer-events: none;
    z-index: 1;
  }
  
  /* Floating effect for cards */
  .carousel-container .card {
    position: relative;
  }
  
  .carousel-container .card::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.3), rgba(118, 75, 162, 0.3));
    border-radius: 17px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
  }
  
  .carousel-container .card:hover::before {
    opacity: 1;
  }
  
  .carousel-container .card {
    flex: 0 0 280px;
    height: 400px;
    transition: all 0.3s ease;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  }
  
  .carousel-container .card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
  }
  
  .carousel-container .card img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform 0.3s ease;
  }
  
  .carousel-container .card:hover img {
    transform: scale(1.03);
  }
  
  .carousel-container .card-content {
    padding: 15px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.9) 100%);
    height: 120px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
  }
  
  .carousel-container .card .title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.3;
    margin-bottom: 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }
  
  .carousel-container .card-info {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
  }
  
  /* Mobile Responsive */
  @media (max-width: 768px) {
    .page-header .page-title {
      font-size: 2.5rem;
    }
  
    .genre-section {
      margin: 0 15px 30px;
      padding: 20px;
    }
  
    .genre-title {
      font-size: 1.6rem;
    }
  
    .carousel-container .card {
      flex: 0 0 220px;
      height: 320px;
    }
  
    .carousel-container .card img {
      height: 220px;
    }
  
    .carousel-container .card-content {
      height: 100px;
      padding: 12px;
    }
  }
  
  /* Active Navigation State */
  .nav a.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
  }
  
  .nav a.active img {
    filter: brightness(0) invert(1);
  }
  
  /* Enhanced Filter Modal Styling */
  .filter-section {
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .filter-section h4 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }
  
  .filter-columns .filter-section h4 {
    font-size: 1rem;
    margin-bottom: 12px;
  }
  
  /* Enhanced Checkbox Grid */
  .checkbox-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    max-height: 200px;
    overflow-y: auto;
    padding-right: 6px;
  }
  
  .filter-columns .checkbox-grid {
    max-height: 160px;
    gap: 6px;
  }
  
  .checkbox-grid::-webkit-scrollbar {
    width: 4px;
  }
  
  .checkbox-grid::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
  }
  
  .checkbox-grid::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 10px;
  }
  
  /* Enhanced Checkbox Styling */
  .checkbox-item {
    position: relative;
  }
  
  .checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .checkbox-label:hover {
    background: rgba(102, 126, 234, 0.1);
    border-color: rgba(102, 126, 234, 0.3);
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
  }
  
  .checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
  }
  
  .checkbox-custom {
    position: relative;
    width: 20px;
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
  }
  
  .checkbox-custom::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg) scale(0);
    transition: all 0.3s ease;
  }
  
  .checkbox-label input[type="checkbox"]:checked + .checkbox-custom {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: #667eea;
  }
  
  .checkbox-label input[type="checkbox"]:checked + .checkbox-custom::after {
    transform: rotate(45deg) scale(1);
  }
  
  .checkbox-text {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary);
    flex: 1;
  }
  
  /* Enhanced Sorting Selector */
  #sortSelect {
    width: 100%;
    padding: 15px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6,9 12,15 18,9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 20px;
    padding-right: 50px;
  }
  
  #sortSelect:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
    background-color: rgba(255, 255, 255, 0.08);
  }
  
  #sortSelect:hover {
    border-color: rgba(102, 126, 234, 0.5);
    background-color: rgba(255, 255, 255, 0.08);
  }
  
  #sortSelect option {
    background: rgba(26, 26, 26, 0.95);
    color: var(--text-primary);
    padding: 10px;
    font-size: 0.9rem;
    font-weight: 500;
  }
  
  /* Enhanced Year Filter */
  .year-filter {
    display: flex;
    align-items: center;
    gap: 15px;
  }
  
  .year-filter input[type="number"] {
    flex: 1;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
  }
  
  .year-filter input[type="number"]:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
    background-color: rgba(255, 255, 255, 0.08);
  }
  
  .year-filter span {
    color: var(--text-secondary);
    font-weight: 700;
    font-size: 1.2rem;
  }
  
  /* Mobile Responsive for Modal */
  @media (max-width: 768px) {
    .checkbox-grid {
      grid-template-columns: 1fr;
      max-height: 150px;
    }
  
    .filter-section {
      padding: 15px;
      margin-bottom: 20px;
    }
  
    #sortSelect {
      font-size: 0.9rem;
      padding: 12px 15px;
    }
  
    .year-filter {
      flex-direction: column;
      gap: 10px;
    }
  
    .year-filter input[type="number"] {
      padding: 10px 12px;
    }
  }
  
  /* Enhanced Episode Numeration */
  .episode-count {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    border-radius: 8px;
    padding: 4px 8px;
    font-weight: 700;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
    transition: transform 0.2s ease;
  }
  
  .episode-count:hover {
    transform: scale(1.05);
  }
  
  
  
  /* Enhanced Modal Close Button */
  .modal-close:hover {
    background: rgba(255, 255, 255, 0.2) !important;
    transform: rotate(90deg);
  }
  
  
  
  .count-number {
    font-size: 1rem;
    font-weight: 800;
    color: white;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
  }
  
  .count-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  
  /* Enhanced info items */
  .info-item {
    transition: all 0.2s ease;
  }
  
  .info-item:hover {
    transform: translateY(-1px);
  }
  
  .search-form {
    display: flex;
    gap: 12px;
    width: 100%;
  }
  
  .search-input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .search-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
  }
  
  .search-btn {
    padding: 12px 24px;
    background: var(--gradient-primary);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
  }
  
  .search-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
  }
  
  .filter-actions {
    display: flex;
    justify-content: flex-end;
  }
  
  .filter-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: #1a73e8;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    border: none;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(60, 64, 67, 0.302), 0 4px 8px rgba(60, 64, 67, 0.149);
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.2s ease;
  }
  
  .filter-button:hover {
    background: #1557b0;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(60, 64, 67, 0.2);
  }
  
  .filter-button:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(60, 64, 67, 0.302);
  }
  
  /* Mobile responsive additional styles */
  }
  
  /* Results info section */
  .results-info {
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    padding: 16px 20px;
    margin: 20px 0;
    border: 1px solid var(--border-color);
  }
  
  .results-info h3 {
    margin: 0;
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
  }
  
  /* Modal Styles */
  .modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    animation: modalFadeIn 0.3s ease-out;
  }
  
  .modal.show {
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .modal-content {
    background: var(--bg-primary);
    border-radius: var(--border-radius-lg);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-color);
    animation: modalSlideIn 0.3s ease-out;
  }
  
  .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 32px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-secondary);
  }
  
  .modal-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }
  
  .modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px;
    border-radius: var(--border-radius);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .modal-close:hover {
    background: var(--bg-card);
    color: var(--text-primary);
  }
  
  .modal-body {
    padding: 32px;
    max-height: 60vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-primary) var(--bg-secondary);
  }
  
  /* Two-column layout for genres and themes */
  .filter-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 32px;
  }
  
  @media (max-width: 768px) {
    .filter-columns {
      grid-template-columns: 1fr;
      gap: 24px;
    }
  }
  
  .modal-body::-webkit-scrollbar {
    width: 6px;
  }
  
  .modal-body::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 3px;
  }
  
  .modal-body::-webkit-scrollbar-thumb {
    background: var(--accent-primary);
    border-radius: 3px;
  }
  
  .filter-section {
    margin-bottom: 32px;
  }
  
  /* Adjust filter section spacing in columns */
  .filter-columns .filter-section {
    margin-bottom: 0;
    padding: 24px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
  }
  
  .filter-section h3 {
    margin: 0 0 16px 0;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--accent-primary);
  }
  
  /* Sorting Options */
  .sort-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  
  .sort-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    border: 2px solid var(--border-color);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .sort-option:hover {
    border-color: var(--accent-primary);
    background: var(--bg-card);
  }
  
  .sort-option input[type="radio"] {
    width: 16px;
    height: 16px;
    accent-color: var(--accent-primary);
  }
  
  .sort-option span {
    font-weight: 500;
    color: var(--text-primary);
  }
  
  /* Genre and Theme Grids */
  .genre-grid,
  .theme-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
  }
  
  .genre-checkbox,
  .theme-checkbox {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    border: 2px solid var(--border-color);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .genre-checkbox:hover,
  .theme-checkbox:hover {
    border-color: var(--accent-secondary);
    background: var(--bg-card);
  }
  
  .genre-checkbox input[type="checkbox"],
  .theme-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--accent-secondary);
  }
  
  .genre-checkbox span,
  .theme-checkbox span {
    font-weight: 500;
    color: var(--text-primary);
  }
  
  .genre-checkbox:has(input:checked),
  .theme-checkbox:has(input:checked) {
    border-color: var(--accent-secondary);
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(139, 92, 246, 0.05));
  }
  
  /* Year Range */
  .year-range {
    display: flex;
    align-items: center;
    gap: 12px;
  }
  
  .year-range input {
    padding: 10px 14px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 1rem;
    width: 100px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  .year-range input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
  }
  
  .year-range span {
    color: var(--text-secondary);
    font-weight: 600;
  }
  
  /* Modal Footer */
  .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 16px;
    padding: 24px 32px;
    border-top: 1px solid var(--border-color);
    background: var(--bg-secondary);
  }
  
  .btn-primary,
  .btn-secondary {
    padding: 12px 24px;
    border: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.9rem;
  }
  
  .btn-primary {
    background: var(--gradient-primary);
    color: white;
  }
  
  .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
  }
  
  .btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
  }
  
  .btn-secondary:hover {
    background: var(--bg-primary);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
  }
  
  /* Modal Animations */
  @keyframes modalFadeIn {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }
  
  @keyframes modalSlideIn {
    from {
      opacity: 0;
      transform: scale(0.9) translateY(-20px);
    }
    to {
      opacity: 1;
      transform: scale(1) translateY(0);
    }
  }
  
  /* Mobile Responsive */
  @media (max-width: 768px) {
    .modal-content {
      width: 95%;
      max-height: 95vh;
    }
  
    .modal-header {
      padding: 20px 24px;
    }
  
    .modal-body {
      padding: 24px;
    }
  
    .modal-footer {
      padding: 20px 24px;
      flex-direction: column;
    }
  
    .sort-options {
      grid-template-columns: 1fr;
    }
  
    .genre-grid,
    .theme-grid {
      grid-template-columns: 1fr;
    }
  
    .btn-primary,
    .btn-secondary {
      width: 100%;
    }
  }
  